function isTest(str){
    let arr = str.split(' ');
    let oddList=[],evenList=[]
    arr.forEach(item=>{
        if(item%2===0) evenList.push(item)
        else oddList.push(item)
    })
    if(evenList.length===1) return evenList[0]
    return oddList[0]
}
console.log(isTest('2 1 1 21'));
